/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package org.sunspotworld.datawrappers;

import com.sun.spot.io.j2me.radiogram.Radiogram;
import java.io.IOException;

/**
 * An interface for a factory that makes IDataWrappers from Radiogram data
 * @author Douglas McClusky
 */
public interface IDataWrapperFactory {
    
    /**
     * Creates an IDataWrapper from the data within rg
     * @param rg
     * @return
     * @throws java.io.IOException
     */
    public abstract DataWrapper constructDataWrapper(byte[] b, int index) throws IOException;
    
    public abstract DataWrapper constructDataWrapper(byte[] b) throws IOException;
}
